package com.hospital.dao;

import com.hospital.entity.FollowUpGroup;
import com.hospital.entity.Patient;
import org.springframework.data.repository.query.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface PatientMapper {
    //查所有随访组对应的患者
    public List<Patient> SelectAll(@Param("page") Integer page, @Param("pageNum") Integer pageNum, @Param("status") String status);

    //查所有患者数量
    public Integer SelectAllCounts(@Param(value = "status") String status);

    //条件查询
    public List<Patient> SelectLike(@Param("page") Integer page, @Param("pageNum") Integer pageNum, @Param("followUpGroup") FollowUpGroup followUpGroup, @Param("patient") Patient patient);

    //条件查询数量
    public Integer SelectLikeCount(@Param("followUpGroup") FollowUpGroup followUpGroup, @Param("patient") Patient patient);

    //查一个患者信息
    public Patient SelectById(Integer id);

    //修改患者信息
    public Integer Update(Patient patient);

    //删除方法
    public Integer Delete(Integer id);
}
